package cn.highset.modules.base.entity;

import cn.highset.base.HighsetBaseEntity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.annotations.SQLDelete;
import org.hibernate.annotations.SQLDeleteAll;
import org.hibernate.annotations.Where;

import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

/**
 * @author Victor
 */
@Data
@Entity
@Table(name = "t_exhibitor")
@TableName("t_exhibitor")
@SQLDelete(sql = "update t_exhibitor set del_flag= 1 where id =?")
@SQLDeleteAll(sql = "update t_exhibitor set del_flag= 1 where id =?")
@Where(clause = "del_flag=0")
@ApiModel(value = "展商")
public class Exhibitor extends HighsetBaseEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "展商名称")
    private String companyName;
    @ApiModelProperty(value = "展商英文名称")
    private String companyNameEn;

    @ApiModelProperty(value = "展商名称拼音")
    private String companyNamePy;
    @ApiModelProperty(value = "展商英文名称拼音")
    private String companyNameEnPy;

    @ApiModelProperty(value = "展位号")
    private String standNo;

    @ApiModelProperty(value = "被收藏数量")
    private Integer collectCount = 0;


    @Transient
    @TableField(exist = false)
    @ApiModelProperty(value = "产品类别id")
    private String productTypeId;

    @Transient
    @TableField(exist = false)
    @ApiModelProperty(value = "产品类别ids")
    private String[] productTypeIds;

    @Transient
    @TableField(exist = false)
    @ApiModelProperty(value = "产品类别名称")
    private String[] productTypeNames;

    @Transient
    @TableField(exist = false)
    @ApiModelProperty(value = "产品类别名称英文")
    private String[] productTypeNameEns;

    @Transient
    @TableField(exist = false)
    @ApiModelProperty(value = "小程序搜索key")
    private String key;

}
